#include "config.h"
#include "Entity.h"
#include "StateOne.h"
#include "EntityManager.hpp"
#include "MessageManager.hpp"

int main()
{
	using namespace walker_sm;

	auto entityA = new Entity();
	EntityManager::GetInstance()->RegisterEntity(entityA);
	auto entityB = new Entity();
	EntityManager::GetInstance()->RegisterEntity(entityB);
	entityB->GetFSM()->SetCurrentState(StateOne::GetInstance());

	for (auto i = 0; i < 3; ++i)
	{
		entityB->Update();
		MessageManager::GetInstance()->DispathMessage(0,i+1,entityA->GetId(), entityB->GetId(), nullptr);
	}

	delete entityA;
	delete entityB;

	system("pause");
	return 0;
}